<template>
	<div>
		<div class="nav">
			<div class="nav-main">
				<div class="nav-main-center">
					<div class="return" v-on:click="back"><Icon type="ios-arrow-back" style="font-size: 25px;" /></div>
					<div class="close" v-on:click="back"><Icon type="md-close" style="font-size: 25px;" /></div>
					<div class="title">经纪人列表</div>
					<div class="massige"><Icon type="ios-chatbubbles-outline" style="font-size: 25px;" /></div>
				</div>
			</div>
		</div>
		<div class="search">
			<div class="search-main">
				<div><Icon type="ios-search" style="font-size: 25px;" /></div>
				<div>请输入商圈、小区、或经纪人的姓名、电话</div>
			</div>
		</div>
		<div class="zhuti">
			<agentchild :agentdata="agentdata"></agentchild>
		</div>
	</div>
</template>

<script>
	import agentchild from "./agentchild";
	export default {
		name: 'agent',
		methods: {
			back() {
				this.$router.go(-1);//返回上一层
			}
		},
		data(){
			return{
				agentdata:[
					{
						// img:require("../../../static/img/agent/headerImg1.png"),
						// name:"陶仁梅",
						// fz:"龚家湾-吉联建兰丽苑店A组",
						// pf:"5.0",
						// people:"1"
					}
				]
			}
		},
		mounted() {
			this.$ajax({
					method: 'post',
					url: '/housing/agent'
				}).then((res)=> {
					this.agentdata=res.data;
				})
				.catch((err)=> {
					console.log(err)
				});
		},
		components:{
	  		  agentchild
		}
	}
</script>

<style scoped>
	.agent{
		width: 100%;
		height: auto;
	}
	.nav{
		width: 100%;
		height: 0.95rem;
		border-bottom: 1px solid #d2d2d2;
		position: fixed;
		background: white;
		top: 0rem;
		z-index: 999;
		padding-top: 0.2rem;
		background: white;
	}
	.nav-main{
		width: 7.09rem;
		height: 100%;
		margin: auto;
		display: flex;
		align-items: center;
	}
	.nav-main-center{
		width: 100%;
		height: 0.4rem;
		display: flex;
		justify-content:space-between ;
		align-items: center;
		position: relative;
	}
	.close{
		position: absolute;
		left: 0.55rem;
	}
	.title{
		font-size: 20px;
		color: black;
	}
	.search{
		width: 100%;
		height: 0.62rem;
		margin-top: 1.2rem;
	}
	.zhuti{
		width: 100%;
		height: auto;
	}
	.search-main{
		width: 7.09rem;
		height: 100%;
		margin: auto;
		background: #e8e8e8;
		display: flex;
		align-items: center;
	}
	.search-main>div:nth-of-type(1){
		margin-left: 0.15rem;
	}
	.search-main>div:nth-of-type(2){
		font-size: 14px;
		margin-left: 0.1rem;
	}
</style>
